package com.haiqi.modules.map.service;

import com.github.pagehelper.PageInfo;
import com.haiqi.common.bean.PageBean;
import com.haiqi.common.persistence.dao.ShipTouchlineMapper;
import com.haiqi.common.persistence.entity.ShipTouchline;
import com.haiqi.common.utils.PageUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by hythzx on 2016/6/29.
 */
@Service
public class TouchLineService {

    @Autowired
    private ShipTouchlineMapper shipTouchlineMapper;

    public PageInfo<ShipTouchline> getDataList(ShipTouchline shipTouchline,PageBean page){
        PageUtils.generatePage(page);
        List<ShipTouchline> dataList = shipTouchlineMapper.getDataList(shipTouchline);
        PageInfo<ShipTouchline> pageInfo = new PageInfo<>(dataList);
        return pageInfo;
    }
}
